<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8" %>
<%@taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html class="iframe-h">
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
    <title>用户管理</title>
    <script type="text/javascript"
            src="${pageContext.request.contextPath}/statics/admin/js/jquery-3.5.0.min.js"></script>
    <script type="text/javascript"
            src="${pageContext.request.contextPath}/statics/admin/bootstrap/js/bootstrap.js"></script>
    <script type="text/javascript" src="${pageContext.request.contextPath}/statics/admin/js/javascript.js"></script>
    <link rel="stylesheet" type="text/css"
          href="${pageContext.request.contextPath}/statics/admin/bootstrap/css/bootstrap.css"/>
    <link rel="stylesheet" type="text/css" href="${pageContext.request.contextPath}/statics/admin/layui/css/layui.css"/>
    <link rel="stylesheet" type="text/css" href="${pageContext.request.contextPath}/statics/admin/css/admin.css"/>
    <link rel="stylesheet" type="text/css" href="${pageContext.request.contextPath}/statics/admin/css/page.css"/>
    <style type="text/css">
        a:hover {
            text-decoration: none;
        }
    </style>
    <script type="text/javascript">
        function toAddUser() {
            window.location.href = "${pageContext.request.contextPath}/admin/toAddUser.do";
        }

        //禁用功能
        $(function () {
            $("ul.pagination li.disabled a").click(function () {
                return false;
            })
        });
    </script>
</head>

<body>
<div class="wrap-container clearfix">
    <div class="column-content-detail">
        <div id="table-list">
            <form action="${pageContext.request.contextPath}/admin/deleteAssistants.do?classification=${classification}"
                  method="post">
                <div class="layui-inline tool-btn">
                    <a style="margin: 5px" class="layui-btn layui-btn-primary"
                       href="${pageContext.request.contextPath}/admin/toUserHelp.do">返回</a>
                    <button class="layui-btn layui-btn-small layui-btn-danger delBtn"
                            type="submit"
                            onclick="if (confirm('确认删除选中的帮助吗?') === false) return false;">
                        <i class="layui-icon" title="删除选中的帮助">&#xe640;</i>
                    </button>
                </div>
                <table class="layui-table" lay-even lay-skin="nob">
                    <colgroup>
                        <col class="hidden-xs" width="10">
                        <col class="hidden-xs" width="50">
                        <col class="hidden-xs" width="50">
                        <col class="hidden-xs" width="120">
                        <col class="hidden-xs" width="100">
                        <col class="hidden-xs" width="150">
                        <col class="hidden-xs" width="200">
                    </colgroup>
                    <thead>
                    <tr>
                        <th class="hidden-xs"><b></b></th>
                        <th><input type="checkbox" name="" lay-skin="primary"
                                   onclick="swapCheck()">&nbsp;&nbsp;<b>全选</b></th>
                        <th class="hidden-xs"><b>Help_id</b></th>
                        <th class="hidden-xs"><b>问题</b></th>
                        <th class="hidden-xs"><b>解决方案</b></th>
                        <th class="hidden-xs"><b>分类</b></th>
                        <th class="hidden-xs"><b>操作</b></th>
                    </tr>
                    </thead>
                    <tbody>
                    <c:forEach items="${assistanceList}" var="assistance">
                        <tr>
                            <td class="hidden-xs"></td>
                            <td><input type="checkbox" name="ids" lay-skin="primary" value="${assistance.helpId}"/></td>
                            <td class="hidden-xs">${assistance.helpId}</td>
                            <td class="hidden-xs">${assistance.situation}</td>
                            <td class="hidden-xs">${assistance.solution}</td>
                            <td class="hidden-xs">${assistance.classification}</td>
                            <td>
                                <div class="layui-inline">
                                    <a class="layui-btn layui-btn-small go-btn"
                                       onclick="window.location.href = '${pageContext.request.contextPath}/admin/toUpdateAssistance.do?helpId=${assistance.helpId}&classification=${classification}'">
                                        <i class="layui-icon" title="编辑帮助信息">&#xe642;</i>
                                    </a>
                                    <a class="layui-btn layui-btn-small layui-btn-danger del-btn"
                                       onclick="if (confirm('确认删除吗?') === false) return false;"
                                       href="${pageContext.request.contextPath}/admin/deleteAssistantsOne.do?helpId=${assistance.helpId}&classification=${classification}">
                                        <i class="layui-icon" title="删除帮助">&#xe640;</i>
                                    </a>
                                </div>
                            </td>
                        </tr>
                    </c:forEach>
                    </tbody>
                </table>
            </form>
        </div>
    </div>

</div>
<script src="${pageContext.request.contextPath}/statics/admin/layui/lay/modules/layer.js"
        type="text/javascript"></script>
<script src="${pageContext.request.contextPath}/statics/admin/layui/layui.js" type="text/javascript"
        charset="utf-8"></script>
<script src="${pageContext.request.contextPath}/statics/admin/js/common.js" type="text/javascript"
        charset="utf-8"></script>
</body>
</html>